<%@ LANGUAGE="VBSCRIPT" %>
<% option explicit%>
<% Response.Expires=0 %>
<!--METADATA NAME="Microsoft ActiveX Data Objects 2.5 Library" TYPE="TypeLib" UUID="{00000205-0000-0010-8000-00AA006D2EA4}"-->
<%
dim Node
Node=request("Node")
if isEmpty(Node) then Node="_P"
	Dim cnn
	Dim connStr
	dim cmd
	dim R
	Set cnn=Server.CreateObject("ADODB.Connection")
    Set cmd=Server.CreateObject("ADODB.Command")
	connStr="Provider=SQLOLEDB.1;Persist Security Info=True;User ID=Test;Password=Test;Initial Catalog=SMS"&Node&";Data Source=EM-HOME"
	cnn.open connStr
	Set cmd.ActiveConnection = cnn
	cmd.CommandType=adCmdStoredProc
	cmd.CommandText = "sp_BankomatDEMO"
	Cmd.Parameters.Append Cmd.CreateParameter("@AutomatNumber", adVarChar, adParamInput,16)
	Cmd.Parameters.Append Cmd.CreateParameter("@Phone", adVarChar, adParamInput,20)
	Cmd.Parameters.Append Cmd.CreateParameter("@Sum", adVarChar, adParamInput,10)
	Cmd.Parameters.Append Cmd.CreateParameter("@Operation", adVarChar, adParamInput,10)
	Cmd.Parameters.Append Cmd.CreateParameter("@PIN", adChar, adParamInput,5)
	Cmd.Parameters.Append Cmd.CreateParameter("@id", adInteger, adParamOutput)
	Cmd.Parameters.Append Cmd.CreateParameter("@Res", adInteger, adParamOutput)
	Cmd.Parameters.Append Cmd.CreateParameter("@Result", adVarChar, adParamOutput,160)
	Cmd("@AutomatNumber")=Request.Querystring("AutomatNumber")
	Cmd("@Phone")=Request.Querystring("Phone")
	Cmd("@Sum")=Request.Querystring("Sum")
	Cmd("@Operation")=Request.Querystring("Operation")
	Cmd("@PIN")=Request.Querystring("PIN")
	cmd.execute
	%>
<Result>
<%=Cmd("@Result")%>
</Result>
<%
	set cmd=nothing
	set cnn=nothing
%>
